package com.kehutong.admin.entity;

import org.coraframework.orm.Entity;
import org.coraframework.orm.annotation.Column;
import org.coraframework.orm.annotation.Table;

import com.kehutong.admin.enums.LogType;

/**
 * 日志
 * @author liuzhen (liuxing521a@163.com)
 * @createTime 2019年4月16日下午5:52:57
 */
@Table("sys_log")
public class Log extends Entity {
	

	private static final long serialVersionUID = 1L;
	
	protected Log(String id) {
		super(id);
	}
	
	@Column(comment="归属公司")
	private String companyNo;
	@Column(comment="归属部门")
	private String companyName;
	
	@Column(comment="归属部门编号")
	private String officeNo;
	@Column(comment="归属部门名称")
	private String officeName;
	
	@Column(comment="日志类型（1：接入日志；2：错误日志）")
	private LogType type; 		

	@Column(comment="操作用户的IP地址")
	private String remote_addr; 	

	@Column(length=256, comment="操作的URI")
	private String request_uri; 	

	@Column(comment="操作的方法[GET,POST...]")
	private String method; 		
	
	@Column(comment="操作提交的数据", dbType = "TEXT")
	private String params; 		
	
	@Column(length=0xFF, comment="操作用户代理信息")
	private String user_agent;	
	
	@Column(comment="异常信息", dbType = "TEXT")
	private String exception; 	

	@Column(comment="操作人")
	private String create_by;

	@Column(comment = "操作人名字")
	private String create_name;
	
	public String getCompanyNo() {
		return companyNo;
	}

	public void setCompanyNo(String companyNo) {
		this.companyNo = companyNo;
	}

	public String getCompanyName() {
		return companyName;
	}

	public void setCompanyName(String companyName) {
		this.companyName = companyName;
	}

	public String getOfficeNo() {
		return officeNo;
	}

	public void setOfficeNo(String officeNo) {
		this.officeNo = officeNo;
	}

	public String getOfficeName() {
		return officeName;
	}

	public void setOfficeName(String officeName) {
		this.officeName = officeName;
	}

	public LogType getType() {
		return type;
	}

	public void setType(LogType type) {
		this.type = type;
	}

	public String getRemote_addr() {
		return remote_addr;
	}

	public void setRemote_addr(String remote_addr) {
		this.remote_addr = remote_addr;
	}

	public String getRequest_uri() {
		return request_uri;
	}

	public void setRequest_uri(String request_uri) {
		this.request_uri = request_uri;
	}

	public String getMethod() {
		return method;
	}

	public void setMethod(String method) {
		this.method = method;
	}

	public String getParams() {
		return params;
	}

	public void setParams(String params) {
		this.params = params;
	}

	public String getUser_agent() {
		return user_agent;
	}

	public void setUser_agent(String user_agent) {
		this.user_agent = user_agent;
	}

	public String getException() {
		return exception;
	}

	public void setException(String exception) {
		this.exception = exception;
	}
	
	public String getCreate_by() {
		return create_by;
	}
	
	public void setCreate_by(String create_by) {
		this.create_by = create_by;
	}

	public String getCreate_name() {
		return create_name;
	}

	public void setCreate_name(String create_name) {
		this.create_name = create_name;
	}
}